import type { IDomEditor, IEditorConfig, IToolbarConfig } from '@wangeditor/editor';
import React from 'react';

export type InsertFnType = (url: string, alt: string, href?: string) => void;

export interface YmRichEditorProps {
  value?: string;
  onChange?: (htmlStr: string) => void;
  toolbarConfig?: Partial<IToolbarConfig>;
  editorConfig?: Partial<IEditorConfig>;
  onEditorCreate?: (editor: IDomEditor) => void;
  editorStyle?: React.CSSProperties;
  fileUploadConfig: {
    dir: string;
    phone?: string;
    maxSize?: number; //以M为单位
  };

  mode?: string;
}
